Optimal. Leaf size=120 \[ \frac {2 \tanh ^{-1}\left (\frac {\sqrt {a+a \sec (c+d x)}}{\sqrt {a}}\right )}{a^{3/2} d}-\frac {\tanh ^{-1}\left (\frac {\sqrt {a+a \sec (c+d x)}}{\sqrt {2} \sqrt {a}}\right )}{2 \sqrt {2} a^{3/2} d}-\frac {1}{3 d (a+a \sec (c+d x))^{3/2}}-\frac {3}{2 a d \sqrt {a+a \sec (c+d x)}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.08, antiderivative size = 120, normalized size of antiderivative = 1.00, number of steps
used = 8, number of rules used = 6, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.286, Rules used = {3965, 87, 157,
162, 65, 213} \begin {gather*} \frac {2 \tanh ^{-1}\left (\frac {\sqrt {a \sec (c+d x)+a}}{\sqrt {a}}\right )}{a^{3/2} d}-\frac {\tanh ^{-1}\left (\frac {\sqrt {a \sec (c+d x)+a}}{\sqrt {2} \sqrt {a}}\right )}{2 \sqrt {2} a^{3/2} d}-\frac {3}{2 a d \sqrt {a \sec (c+d x)+a}}-\frac {1}{3 d (a \sec (c+d x)+a)^{3/2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 65
Rule 87
Rule 157
Rule 162
Rule 213
Rule 3965
Rubi steps
\begin {align*} \int \frac {\cot (c+d x)}{(a+a \sec (c+d x))^{3/2}} \, dx &=\frac {a^2 \text {Subst}\left (\int \frac {1}{x (-a+a x) (a+a x)^{5/2}} \, dx,x,\sec (c+d x)\right )}{d}\\ &=-\frac {1}{3 d (a+a \sec (c+d x))^{3/2}}+\frac {\text {Subst}\left (\int \frac {2 a^2-a^2 x}{x (-a+a x) (a+a x)^{3/2}} \, dx,x,\sec (c+d x)\right )}{2 a d}\\ &=-\frac {1}{3 d (a+a \sec (c+d x))^{3/2}}-\frac {3}{2 a d \sqrt {a+a \sec (c+d x)}}-\frac {\text {Subst}\left (\int \frac {-2 a^4+\frac {3 a^4 x}{2}}{x (-a+a x) \sqrt {a+a x}} \, dx,x,\sec (c+d x)\right )}{2 a^4 d}\\ &=-\frac {1}{3 d (a+a \sec (c+d x))^{3/2}}-\frac {3}{2 a d \sqrt {a+a \sec (c+d x)}}+\frac {\text {Subst}\left (\int \frac {1}{(-a+a x) \sqrt {a+a x}} \, dx,x,\sec (c+d x)\right )}{4 d}-\frac {\text {Subst}\left (\int \frac {1}{x \sqrt {a+a x}} \, dx,x,\sec (c+d x)\right )}{a d}\\ &=-\frac {1}{3 d (a+a \sec (c+d x))^{3/2}}-\frac {3}{2 a d \sqrt {a+a \sec (c+d x)}}-\frac {2 \text {Subst}\left (\int \frac {1}{-1+\frac {x^2}{a}} \, dx,x,\sqrt {a+a \sec (c+d x)}\right )}{a^2 d}+\frac {\text {Subst}\left (\int \frac {1}{-2 a+x^2} \, dx,x,\sqrt {a+a \sec (c+d x)}\right )}{2 a d}\\ &=\frac {2 \tanh ^{-1}\left (\frac {\sqrt {a+a \sec (c+d x)}}{\sqrt {a}}\right )}{a^{3/2} d}-\frac {\tanh ^{-1}\left (\frac {\sqrt {a+a \sec (c+d x)}}{\sqrt {2} \sqrt {a}}\right )}{2 \sqrt {2} a^{3/2} d}-\frac {1}{3 d (a+a \sec (c+d x))^{3/2}}-\frac {3}{2 a d \sqrt {a+a \sec (c+d x)}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] Result contains higher order function than in optimal. Order 5 vs. order 3 in
optimal.
time = 0.07, size = 60, normalized size = 0.50 \begin {gather*} \frac {\, _2F_1\left (-\frac {3}{2},1;-\frac {1}{2};\frac {1}{2} (1+\sec (c+d x))\right )-2 \, _2F_1\left (-\frac {3}{2},1;-\frac {1}{2};1+\sec (c+d x)\right )}{3 d (a (1+\sec (c+d x)))^{3/2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(375\) vs.
\(2(95)=190\).
time = 0.17, size = 376, normalized size = 3.13
method | result | size |
default | \(-\frac {\left (-1+\cos \left (d x +c \right )\right )^{2} \left (12 \sqrt {-\frac {2 \cos \left (d x +c \right )}{1+\cos \left (d x +c \right )}}\, \arctan \left (\frac {\sqrt {-\frac {2 \cos \left (d x +c \right )}{1+\cos \left (d x +c \right )}}\, \sqrt {2}}{2}\right ) \left (\cos ^{2}\left (d x +c \right )\right ) \sqrt {2}+3 \sqrt {-\frac {2 \cos \left (d x +c \right )}{1+\cos \left (d x +c \right )}}\, \arctan \left (\frac {1}{\sqrt {-\frac {2 \cos \left (d x +c \right )}{1+\cos \left (d x +c \right )}}}\right ) \left (\cos ^{2}\left (d x +c \right )\right )+24 \cos \left (d x +c \right ) \sqrt {-\frac {2 \cos \left (d x +c \right )}{1+\cos \left (d x +c \right )}}\, \arctan \left (\frac {\sqrt {-\frac {2 \cos \left (d x +c \right )}{1+\cos \left (d x +c \right )}}\, \sqrt {2}}{2}\right ) \sqrt {2}+6 \cos \left (d x +c \right ) \sqrt {-\frac {2 \cos \left (d x +c \right )}{1+\cos \left (d x +c \right )}}\, \arctan \left (\frac {1}{\sqrt {-\frac {2 \cos \left (d x +c \right )}{1+\cos \left (d x +c \right )}}}\right )+12 \sqrt {-\frac {2 \cos \left (d x +c \right )}{1+\cos \left (d x +c \right )}}\, \arctan \left (\frac {\sqrt {-\frac {2 \cos \left (d x +c \right )}{1+\cos \left (d x +c \right )}}\, \sqrt {2}}{2}\right ) \sqrt {2}+22 \left (\cos ^{2}\left (d x +c \right )\right )+3 \sqrt {-\frac {2 \cos \left (d x +c \right )}{1+\cos \left (d x +c \right )}}\, \arctan \left (\frac {1}{\sqrt {-\frac {2 \cos \left (d x +c \right )}{1+\cos \left (d x +c \right )}}}\right )+18 \cos \left (d x +c \right )\right ) \sqrt {\frac {a \left (1+\cos \left (d x +c \right )\right )}{\cos \left (d x +c \right )}}}{12 d \sin \left (d x +c \right )^{4} a^{2}}\) | \(376\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 228 vs.
\(2 (95) = 190\).
time = 3.03, size = 485, normalized size = 4.04 \begin {gather*} \left [\frac {3 \, \sqrt {2} {\left (\cos \left (d x + c\right )^{2} + 2 \, \cos \left (d x + c\right ) + 1\right )} \sqrt {a} \log \left (-\frac {2 \, \sqrt {2} \sqrt {a} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \cos \left (d x + c\right ) - 3 \, a \cos \left (d x + c\right ) - a}{\cos \left (d x + c\right ) - 1}\right ) + 12 \, {\left (\cos \left (d x + c\right )^{2} + 2 \, \cos \left (d x + c\right ) + 1\right )} \sqrt {a} \log \left (-8 \, a \cos \left (d x + c\right )^{2} - 4 \, {\left (2 \, \cos \left (d x + c\right )^{2} + \cos \left (d x + c\right )\right )} \sqrt {a} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} - 8 \, a \cos \left (d x + c\right ) - a\right ) - 4 \, {\left (11 \, \cos \left (d x + c\right )^{2} + 9 \, \cos \left (d x + c\right )\right )} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}}}{24 \, {\left (a^{2} d \cos \left (d x + c\right )^{2} + 2 \, a^{2} d \cos \left (d x + c\right ) + a^{2} d\right )}}, \frac {3 \, \sqrt {2} {\left (\cos \left (d x + c\right )^{2} + 2 \, \cos \left (d x + c\right ) + 1\right )} \sqrt {-a} \arctan \left (\frac {\sqrt {2} \sqrt {-a} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \cos \left (d x + c\right )}{a \cos \left (d x + c\right ) + a}\right ) - 12 \, {\left (\cos \left (d x + c\right )^{2} + 2 \, \cos \left (d x + c\right ) + 1\right )} \sqrt {-a} \arctan \left (\frac {2 \, \sqrt {-a} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \cos \left (d x + c\right )}{2 \, a \cos \left (d x + c\right ) + a}\right ) - 2 \, {\left (11 \, \cos \left (d x + c\right )^{2} + 9 \, \cos \left (d x + c\right )\right )} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}}}{12 \, {\left (a^{2} d \cos \left (d x + c\right )^{2} + 2 \, a^{2} d \cos \left (d x + c\right ) + a^{2} d\right )}}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\cot {\left (c + d x \right )}}{\left (a \left (\sec {\left (c + d x \right )} + 1\right )\right )^{\frac {3}{2}}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 1.02, size = 164, normalized size = 1.37 \begin {gather*} \frac {\frac {3 \, \sqrt {2} \arctan \left (\frac {\sqrt {-a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + a}}{\sqrt {-a}}\right )}{\sqrt {-a} a \mathrm {sgn}\left (\cos \left (d x + c\right )\right )} - \frac {24 \, \arctan \left (\frac {\sqrt {2} \sqrt {-a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + a}}{2 \, \sqrt {-a}}\right )}{\sqrt {-a} a \mathrm {sgn}\left (\cos \left (d x + c\right )\right )} - \frac {\sqrt {2} {\left ({\left (-a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + a\right )}^{\frac {3}{2}} a^{6} + 9 \, \sqrt {-a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + a} a^{7}\right )}}{a^{9} \mathrm {sgn}\left (\cos \left (d x + c\right )\right )}}{12 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {\mathrm {cot}\left (c+d\,x\right )}{{\left (a+\frac {a}{\cos \left (c+d\,x\right )}\right )}^{3/2}} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________